package com.sinping.qh.dto.admin;

import com.fasterxml.jackson.annotation.JsonProperty;
import com.sinping.qh.dto.base.BaseDTO;
import lombok.Data;
import org.hibernate.validator.constraints.NotBlank;

import javax.validation.constraints.Pattern;
import java.io.Serializable;

/**
 * 楼宇
 *
 * @author Tiansx
 * @create 2018-05-29 13:43
 **/
@Data
public class ApiBuildingDto extends BaseDTO implements Serializable{

    private static final long serialVersionUID = 6410829157637840904L;

    /**
     * 楼宇名称
     */
    @NotBlank(message = "楼宇名称不能为空")
    @Pattern(regexp = "^.{1,30}$",message = "楼宇名称不超过30个字符")
    @JsonProperty("building_name")
    private String buildingName;
    /**
     * 创建人id
     */
    @JsonProperty("create_user_id")
    private String createUserId;
    /**
     * 修改人id
     */
    @JsonProperty("update_user_id")
    private String updateUserId;
}
